﻿using System;
using System.Collections.Generic;

namespace SmartCommunity.Models;

/// <summary>
/// 用户
/// </summary>
public partial class UserEntity
{
    /// <summary>
    /// 用户ID
    /// </summary>
    public int UserId { get; set; }

    /// <summary>
    /// 登录用户名
    /// </summary>
    public string Username { get; set; } = null!;

    /// <summary>
    /// 昵称
    /// </summary>
    public string Nickname { get; set; } = null!;

    /// <summary>
    /// 登录密码
    /// </summary>
    public string Password { get; set; } = null!;

    /// <summary>
    /// 手机号码
    /// </summary>
    public string Cellphone { get; set; } = null!;

    /// <summary>
    /// 电子邮箱
    /// </summary>
    public string? Email { get; set; }

    /// <summary>
    /// 性别：M/F/O
    /// </summary>
    public string Gender { get; set; } = null!;

    /// <summary>
    /// 是否作废
    /// </summary>
    public bool Disabled { get; set; }

    /// <summary>
    /// 用户状态:0正常；1密码锁定；2密码过期；
    /// </summary>
    public UserStatus Status { get; set; }

    /// <summary>
    /// 头像
    /// </summary>
    public string? Avatar { get; set; }

    /// <summary>
    /// 备注
    /// </summary>
    public string? Remark { get; set; }

    /// <summary>
    /// 创建人
    /// </summary>
    public string CreatedBy { get; set; } = null!;

    /// <summary>
    /// 创建时间
    /// </summary>
    public DateTime CreatedTime { get; set; }

    /// <summary>
    /// 修改人
    /// </summary>
    public string UpdatedBy { get; set; } = null!;

    /// <summary>
    /// 修改时间
    /// </summary>
    public DateTime UpdatedTime { get; set; }

    public virtual ICollection<RoleEntity> Roles { get; set; } = new List<RoleEntity>();
}
